feat(compat): set a2a-version header to 1.0.0#764
Conversation
Summary of ChangesHello, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request enhances the client's communication by automatically including a protocol version header in all requests. This change standardizes how the client identifies its protocol version to services, which is crucial for maintaining compatibility and enabling future API evolution. It ensures that both HTTPX and gRPC clients consistently send this version information, improving robustness and clarity in client-server interactions. Highlights
Changelog
Activity
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
There was a problem hiding this comment.
Code Review
This pull request adds the X-A2A-Version header to outgoing requests, which is a good step for protocol compatibility. The implementation looks mostly correct, with changes across HTTP and gRPC transports. I've left a couple of suggestions: one to improve code clarity by removing a redundant operation in the ClientFactory, and another to correct a type hint in the gRPC transport to align with the new logic and repository style guide.
a872513 to
a680105
Compare
a680105 to
77c1c99
Compare
77c1c99 to
b8da2ed
Compare
🤖 I have created a release *beep* *boop* --- ### ⚠ BREAKING CHANGES * **spec**: upgrade SDK to A2A 1.0 spec and use proto-based types ([#572](#572), [#665](#665), [#804](#804), [#765](#765)) * **client:** introduce ServiceParameters for extensions and include it in ClientCallContext ([#784](#784)) * **client:** rename "callback" -> "push_notification_config" ([#749](#749)) * **client:** transport agnostic interceptors ([#796](#796)) ([a910cbc](a910cbc)) * add `protocol_version` column to Task and PushNotificationConfig models and create a migration ([#789](#789)) ([2e2d431](2e2d431)) * **server:** implement `Resource Scoping` for tasks and push notifications ([#709](#709)) ([f0d4669](f0d4669)) ### Features * add GetExtendedAgentCardRequest as input parameter to GetExtendedAgentCard method ([#767](#767)) ([13a092f](13a092f)) * add validation for the JSON-RPC version ([#808](#808)) ([6eb7e41](6eb7e41)) * **client:** expose close() and async context manager support on abstract Client ([#719](#719)) ([e25ba7b](e25ba7b)) * **compat:** AgentCard backward compatibility helpers and tests ([#760](#760)) ([81f3494](81f3494)) * **compat:** GRPC client compatible with 0.3 server ([#779](#779)) ([0ebca93](0ebca93)) * **compat:** GRPC server compatible with 0.3 client ([#772](#772)) ([80d827a](80d827a)) * **compat:** legacy v0.3 protocol models, conversion logic and utilities ([#754](#754)) ([26835ad](26835ad)) * **compat:** REST and JSONRPC clients compatible with 0.3 servers ([#798](#798)) ([08794f7](08794f7)) * **compat:** REST and JSONRPC servers compatible with 0.3 clients ([#795](#795)) ([9856054](9856054)) * **compat:** set a2a-version header to 1.0.0 ([#764](#764)) ([4cb68aa](4cb68aa)) * **compat:** unify v0.3 REST url prefix and expand cross-version tests ([#820](#820)) ([0925f0a](0925f0a)) * database forward compatibility: make `owner` field optional ([#812](#812)) ([cc29d1f](cc29d1f)) * handle tenant in Client ([#758](#758)) ([5b354e4](5b354e4)) * implement missing push notifications related methods ([#711](#711)) ([041f0f5](041f0f5)) * implement rich gRPC error details per A2A v1.0 spec ([#790](#790)) ([245eca3](245eca3)) * **rest:** add tenant support to rest ([#773](#773)) ([4771b5a](4771b5a)) * send task as a first subscribe event ([#716](#716)) ([e71ac62](e71ac62)) * **server, grpc:** Implement tenant context propagation for gRPC requests. ([#781](#781)) ([164f919](164f919)) * **server, json-rpc:** Implement tenant context propagation for JSON-RPC requests. ([#778](#778)) ([72a330d](72a330d)) * **server:** add v0.3 legacy compatibility for database models ([#783](#783)) ([08c491e](08c491e)) * **spec:** add `tasks/list` method with filtering and pagination to the specification ([#511](#511)) ([d5818e5](d5818e5)) * use StreamResponse as push notifications payload ([#724](#724)) ([a149a09](a149a09)) * **rest:** update REST error handling to use `google.rpc.Status` ([#838](#838)) ([ea7d3ad](ea7d3ad)) ### Bug Fixes * add history length and page size validations ([#726](#726)) ([e67934b](e67934b)) * allign error codes with the latest spec ([#826](#826)) ([709b1ff](709b1ff)) * **client:** align send_message signature with BaseClient ([#740](#740)) ([57cb529](57cb529)) * get_agent_card trailing slash when agent_card_path="" ([#799](#799)) ([#800](#800)) ([a55c97e](a55c97e)) * handle parsing error in REST ([#806](#806)) ([bbd09f2](bbd09f2)) * Improve error handling for Timeout exceptions on REST and JSON-RPC clients ([#690](#690)) ([2acd838](2acd838)) * Improve streaming errors handling ([#576](#576)) ([7ea7475](7ea7475)) * properly handle unset and zero history length ([#717](#717)) ([72a1007](72a1007)) * return entire history when history_length=0 ([#537](#537)) ([acdc0de](acdc0de)) * return mandatory fields from list_tasks ([#710](#710)) ([6132053](6132053)) * taskslist error on invalid page token and response serialization ([#814](#814)) ([a102d31](a102d31)) * use correct REST path for Get Extended Agent Card operation ([#769](#769)) ([ced3f99](ced3f99)) * Use POST method for REST endpoint /tasks/{id}:subscribe ([#843](#843)) ([a0827d0](a0827d0)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please). --------- Co-authored-by: Ivan Shymko <ishymko@google.com>
…ub-actions group (#1070) Bumps the github-actions group with 1 update: [softprops/action-gh-release](https://github.com/softprops/action-gh-release). Updates `softprops/action-gh-release` from 2 to 3 <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/softprops/action-gh-release/releases">softprops/action-gh-release's releases</a>.</em></p> <blockquote> <h2>v3.0.0</h2> <p><code>3.0.0</code> is a major release that moves the action runtime from Node 20 to Node 24. Use <code>v3</code> on GitHub-hosted runners and self-hosted fleets that already support the Node 24 Actions runtime. If you still need the last Node 20-compatible line, stay on <code>v2.6.2</code>.</p> <h2>What's Changed</h2> <h3>Other Changes 🔄</h3> <ul> <li>Move the action runtime and bundle target to Node 24</li> <li>Update <code>@types/node</code> to the Node 24 line and allow future Dependabot updates</li> <li>Keep the floating major tag on <code>v3</code>; <code>v2</code> remains pinned to the latest <code>2.x</code> release</li> </ul> <h2>v2.6.2</h2> <!-- raw HTML omitted --> <h2>What's Changed</h2> <h3>Other Changes 🔄</h3> <ul> <li>chore(deps): bump picomatch from 4.0.3 to 4.0.4 by <a href="https://github.com/dependabot"><code>@dependabot</code></a>[bot] in <a href="https://redirect.github.com/softprops/action-gh-release/pull/775">softprops/action-gh-release#775</a></li> <li>chore(deps): bump brace-expansion from 5.0.4 to 5.0.5 by <a href="https://github.com/dependabot"><code>@dependabot</code></a>[bot] in <a href="https://redirect.github.com/softprops/action-gh-release/pull/777">softprops/action-gh-release#777</a></li> <li>chore(deps): bump vite from 8.0.0 to 8.0.5 by <a href="https://github.com/dependabot"><code>@dependabot</code></a>[bot] in <a href="https://redirect.github.com/softprops/action-gh-release/pull/781">softprops/action-gh-release#781</a></li> </ul> <p><strong>Full Changelog</strong>: <a href="https://github.com/softprops/action-gh-release/compare/v2...v2.6.2">https://github.com/softprops/action-gh-release/compare/v2...v2.6.2</a></p> <h2>v2.6.1</h2> <p><code>2.6.1</code> is a patch release focused on restoring linked discussion thread creation when <code>discussion_category_name</code> is set. It fixes <code>[#764](https://github.com/softprops/action-gh-release/issues/764)</code>, where the draft-first publish flow stopped carrying the discussion category through the final publish step.</p> <p>If you still hit an issue after upgrading, please open a report with the bug template and include a minimal repro or sanitized workflow snippet where possible.</p> <h2>What's Changed</h2> <h3>Bug fixes 🐛</h3> <ul> <li>fix: preserve discussion category on publish by <a href="https://github.com/chenrui333"><code>@chenrui333</code></a> in <a href="https://redirect.github.com/softprops/action-gh-release/pull/765">softprops/action-gh-release#765</a></li> </ul> <h2>v2.6.0</h2> <p><code>2.6.0</code> is a minor release centered on <code>previous_tag</code> support for <code>generate_release_notes</code>, which lets workflows pin GitHub's comparison base explicitly instead of relying on the default range. It also includes the recent concurrent asset upload recovery fix, a <code>working_directory</code> docs sync, a checked-bundle freshness guard for maintainers, and clearer immutable-prerelease guidance where GitHub platform behavior imposes constraints on how prerelease asset uploads can be published.</p> <p>If you still hit an issue after upgrading, please open a report with the bug template and include a minimal repro or sanitized workflow snippet where possible.</p> <h2>What's Changed</h2> <!-- raw HTML omitted --> </blockquote> <p>... (truncated)</p> </details> <details> <summary>Changelog</summary> <p><em>Sourced from <a href="https://github.com/softprops/action-gh-release/blob/master/CHANGELOG.md">softprops/action-gh-release's changelog</a>.</em></p> <blockquote> <h2>0.1.13</h2> <ul> <li>fix issue with multiple runs concatenating release bodies <a href="https://redirect.github.com/softprops/action-gh-release/pull/145">#145</a></li> </ul> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/softprops/action-gh-release/commit/b4309332981a82ec1c5618f44dd2e27cc8bfbfda"><code>b430933</code></a> release: cut v3.0.0 for Node 24 upgrade (<a href="https://redirect.github.com/softprops/action-gh-release/issues/670">#670</a>)</li> <li><a href="https://github.com/softprops/action-gh-release/commit/c2e35e05a74208bafbfcbdae5ebc9da7236e980f"><code>c2e35e0</code></a> chore(deps): bump the npm group across 1 directory with 7 updates (<a href="https://redirect.github.com/softprops/action-gh-release/issues/783">#783</a>)</li> <li>See full diff in <a href="https://github.com/softprops/action-gh-release/compare/v2...v3">compare view</a></li> </ul> </details> <br /> [](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) --- <details> <summary>Dependabot commands and options</summary> <br /> You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot show <dependency name> ignore conditions` will show all of the ignore conditions of the specified dependency - `@dependabot ignore <dependency name> major version` will close this group update PR and stop Dependabot creating any more for the specific dependency's major version (unless you unignore this specific dependency's major version or upgrade to it yourself) - `@dependabot ignore <dependency name> minor version` will close this group update PR and stop Dependabot creating any more for the specific dependency's minor version (unless you unignore this specific dependency's minor version or upgrade to it yourself) - `@dependabot ignore <dependency name>` will close this group update PR and stop Dependabot creating any more for the specific dependency (unless you unignore this specific dependency or upgrade to it yourself) - `@dependabot unignore <dependency name>` will remove all of the ignore conditions of the specified dependency - `@dependabot unignore <dependency name> <ignore condition>` will remove the ignore condition of the specified dependency and ignore conditions </details> Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Iva Sokolaj <102302011+sokoliva@users.noreply.github.com>
Description
Thank you for opening a Pull Request!
Before submitting your PR, there are a few things you can do to make sure it goes smoothly:
CONTRIBUTINGGuide.fix:which represents bug fixes, and correlates to a SemVer patch.feat:represents a new feature, and correlates to a SemVer minor.feat!:, orfix!:,refactor!:, etc., which represent a breaking change (indicated by the!) and will result in a SemVer major.bash scripts/format.shfrom the repository root to format)